#ifndef Inp_CROPROT_H
#define Inp_CROPROT_H

#include "stdafx.h"
//using namespace std;
class Inp_croprot
{
	int set_croprot_from_croplist2D (list2d *croplist,time_intervall timint_mod,
	string sitename);
	int set_croprot_from_plotprops(map<string,double> &plotprops,list2d *croplist,
		time_intervall timint_mode,string sitename);
	int set_croprot_from_file(time_intervall timint_mod);
public:
	tempmap <string,double> *ptr;
	vector <string> variables;
	time_intervall timint_mod;
	string root;
	string name;
	string suffix;
	string time_horizon_id;
	map <string,int> CONT;

	Inp_croprot(
		map<string,int> &ICONT,
		vector <string> &ivariables,
		string intervall_mode,
		int multipli,
		double dur,
		string itime_horizon_id,
		time_intervall itimint_mod,
		string iroot,
		string iname,
		string isuffix
		)
	{
		CONT=ICONT;
		variables=ivariables;
		time_horizon_id=itime_horizon_id;
		timint_mod=itimint_mod;
		root=iroot;
		name=iname;
		suffix=isuffix;	
		ptr=new tempmap <string,double> (0,-999999,intervall_mode,multipli,dur);
		
	}
	~Inp_croprot()
	{
		delete (ptr);
	}
	int set_input(
		list2d *croplist,
		string sitename,
		map <string,double> &plotprops);
};
#endif